import {BasicColumn} from '/@/components/Table';
import {FormSchema} from '/@/components/Table';
import {h} from 'vue';
import {Switch} from 'ant-design-vue';

export const columns: BasicColumn[] = [
  {
    title: '',
    dataIndex: 'organizationId',
    width: 200,
  },
  {
    title: '',
    dataIndex: 'companyId',
    width: 200,
  },
  {
    title: '角色编码',
    dataIndex: 'roleCode',
    width: 200,
  },
  {
    title: '角色名称',
    dataIndex: 'roleName',
    width: 200,
  },
  {
    title: '状态:0-无效 1-有效',
    dataIndex: 'status',
    width: 200,
  },
  {
    title: '角色类型',
    dataIndex: 'roleType',
    width: 200,
  },
  {
    title: '角色描述',
    dataIndex: 'roleDesc',
    width: 200,
  },
  {
    title: '',
    dataIndex: 'createTime',
    width: 200,
  },
  {
    title: '',
    dataIndex: 'updateTime',
    width: 200,
  },
  {
    title: '保留数据0-否 1-是 不允许删除',
    dataIndex: 'isPersist',
    width: 200,
  },
];

export const searchFormSchema: FormSchema[] = [];

export const formSchema: FormSchema[] = [
  {
    label: '',
    field: 'organizationId',
    component: 'Input',
    required: true,
  },
  {
    label: '',
    field: 'companyId',
    component: 'Input',
    required: true,
  },
  {
    label: '角色编码',
    field: 'roleCode',
    component: 'Input',
    required: true,
  },
  {
    label: '角色名称',
    field: 'roleName',
    component: 'Input',
    required: true,
  },
  {
    label: '状态:0-无效 1-有效',
    field: 'status',
    component: 'Input',
    required: true,
  },
  {
    label: '角色类型',
    field: 'roleType',
    component: 'Input',
    required: true,
  },
  {
    label: '角色描述',
    field: 'roleDesc',
    component: 'Input',
    required: true,
  },
  {
    label: '',
    field: 'createTime',
    component: 'Input',
    required: true,
  },
  {
    label: '',
    field: 'updateTime',
    component: 'Input',
    required: true,
  },
  {
    label: '保留数据0-否 1-是 不允许删除',
    field: 'isPersist',
    component: 'Input',
    required: true,
  },
];
